package snooker.scoreboard.button;

import android.content.res.Resources;
import android.view.View.OnClickListener;
import android.widget.ImageView;

public class FoulButton extends AbstractThreeStateImage {
	
	private boolean checked = false;
	
	public FoulButton(ImageView v, Resources r, int resource1, int resource2, int resource3) {
		super(v, r, resource1, resource2, resource3);
	}
	
	public void setChecked(boolean checked) {
		this.checked = checked;
		if (checked) {
			setState2();
		} else {
			setState1();
		}
	}
	
	public boolean isChecked() {
		return checked;
	}
	
	public void setOnClickListener(OnClickListener listener) {
		super.setOnClickListener(listener);
	}
}
